package com.example.qihuibao.widget.dialog

import android.widget.ProgressBar
import com.example.qihuibao.R
import com.example.qihuibao.base.BaseDialogFragment

/**
 *@author: cww
 *@desc:
 *@date: 5/16/23 10:58 AM
 */
class ProgressDialog : BaseDialogFragment(R.layout.dialog_progress) {

    private var pb:ProgressBar? = null
    private var max = 0

    override fun initView() {
        pb = mView?.findViewById<ProgressBar>(R.id.pb)
        pb?.max = max
    }

    fun setMax(max:Int) {
        this.max = max
        pb?.max = max
    }

    fun setProgress(progress: Int) {
        pb?.progress = progress
    }

}